package com.taotao.slink;

import com.taotao.slink.service.ShortLinkService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.ApplicationArguments;
import org.springframework.boot.ApplicationRunner;
import org.springframework.stereotype.Component;

/**
 * <p>
 *
 * </p>
 *
 * @author fanbeibei
 * @version 1.0.0
 * @date 2023/6/26 14:18
 */
@Component
public class LoadLinkRunner implements ApplicationRunner {


    @Autowired
    private ShortLinkService shortLinkService;

    @Override
    public void run(ApplicationArguments args) throws Exception {
        shortLinkService.loadAllShortLink();
    }
}
